﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace IMIS_ERP.Web.ERP_Manager
{
    public partial class EM_Page_Top : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                try
                {
                    ShowTopInfo();
                    //Set_Hpl();
                }
                catch
                {
                    Response.Redirect("Quit.aspx");
                }
            }
        }

        /// <summary>绑定头部用户信息
        ///     <remarks>2011-03-07 河大信管团队-朱胜贤</remarks>
        /// </summary>
        private void ShowTopInfo()
        {
            lblUId.Text = checkright1.GetUId();
            lblUName.Text = checkright1.GetUName();
            lblRule.Text = Session["UType"].ToString();
        }
        
        ///// <summary>
        /////     <remarks>2011-03-07 河大信管团队-朱胜贤</remarks>
        ///// </summary>
        //private void Set_Hpl()
        //{
        //    hplSale.Visible = false;
        //    hplSearch.Visible = false;
        //    if (Session["UType"].ToString() == "财务人员")
        //    {
        //        hplSale.Visible = true;
        //        hplSearch.Visible = true;
        //    }
        //}

        /// <summary>单击按钮事件：退出
        ///     <remarks>2010-12-02 河大信管团队-水亚亚</remarks>
        /// </summary>
        protected void lbtnLogout_Click(object sender, EventArgs e)
        {
            Response.Redirect("Quit.aspx");
        }
    }
}                                                                             